import os


# if __name__=="__main__":
#     for i in range(16000, 0, -1):
#         curfile="Kitchen/Kitchen/kitchen"+str(i)+".jpg"#从1开始
#         fileindex=int(curfile[23:][:-4])
#         if fileindex<=15:
#             break
#         #从16开始每个+1
#         os.rename(curfile,"Kitchen/Kitchen/Kitchen"+str(fileindex+1)+".jpg")
#     print(len("Kitchen/Kitchen/kitchen1.jpg"))
#     print(int("Kitchen/Kitchen/kitchen222.jpg"[23:][:-4]))
#     for i in range(16000, 0, -1):print(i)


# if __name__=="__main__":
#     for i in range(3, 16003):
#         curfile="Other/Other/other"+str(i)+".jpg"#从1开始
#         fileindex=int(curfile[17:][:-4])
# #全-2
#         os.rename(curfile,"Other/Other/other"+str(fileindex-2)+".jpg")
#     # print(len("Other/Other/other1.jpg"))
#     # print(len("Other/Other/other"))
#     # print("Other/Other/other1777.jpg"[17:][:-4])
#
#     # for i in range(3, 16003):print(i)



if __name__=="__main__":
    for i in range(3, 16003):
        curfile="Recyclable/Recyclable/recyclable"+str(i)+".jpg"#从1开始
        fileindex=int(curfile[32:][:-4])
#全-2
        os.rename(curfile,"Recyclable/Recyclable/recyclable"+str(fileindex-2)+".jpg")
#     print(len("Recyclable/Recyclable/recyclable3.jpg"))
#     print(len("Recyclable/Recyclable/recyclable"))
#     print("Recyclable/Recyclable/recyclable11112.jpg"[32:][:-4])

    # for i in range(3, 16003):print(i)